// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.UniqueConstraint;

/**
 * Wishlist generated by hbm2java
 */
@Entity
@Table(name = "wishlist", catalog = "magento", uniqueConstraints = @UniqueConstraint(columnNames = "customer_id"))
public class Wishlist implements java.io.Serializable {

	private Integer wishlistId;
	private CustomerEntity customerEntity;
	private short shared;
	private String sharingCode;
	private Date updatedAt;
	private Set wishlistItems = new HashSet(0);

	public Wishlist() {
	}

	public Wishlist(CustomerEntity customerEntity, short shared) {
		this.customerEntity = customerEntity;
		this.shared = shared;
	}

	public Wishlist(CustomerEntity customerEntity, short shared,
			String sharingCode, Date updatedAt, Set wishlistItems) {
		this.customerEntity = customerEntity;
		this.shared = shared;
		this.sharingCode = sharingCode;
		this.updatedAt = updatedAt;
		this.wishlistItems = wishlistItems;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "wishlist_id", unique = true, nullable = false)
	public Integer getWishlistId() {
		return this.wishlistId;
	}

	public void setWishlistId(Integer wishlistId) {
		this.wishlistId = wishlistId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "customer_id", unique = true, nullable = false)
	public CustomerEntity getCustomerEntity() {
		return this.customerEntity;
	}

	public void setCustomerEntity(CustomerEntity customerEntity) {
		this.customerEntity = customerEntity;
	}

	@Column(name = "shared", nullable = false)
	public short getShared() {
		return this.shared;
	}

	public void setShared(short shared) {
		this.shared = shared;
	}

	@Column(name = "sharing_code", length = 32)
	public String getSharingCode() {
		return this.sharingCode;
	}

	public void setSharingCode(String sharingCode) {
		this.sharingCode = sharingCode;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "updated_at", length = 19)
	public Date getUpdatedAt() {
		return this.updatedAt;
	}

	public void setUpdatedAt(Date updatedAt) {
		this.updatedAt = updatedAt;
	}

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "wishlist")
	public Set getWishlistItems() {
		return this.wishlistItems;
	}

	public void setWishlistItems(Set wishlistItems) {
		this.wishlistItems = wishlistItems;
	}

}
